package database;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.Proxy;

import constants.Constants;



	
	@Entity
	@Table(name = "t_agent")
	@Proxy(lazy = false)
	public class MAgent {

	  private int id;
	  private String name;
	  private int agentId=Constants.NO_AGENTE;
	  private MWorldObject objectReference; 	  
	  

	  // ----------------------------------------

	  @Id
	  @GeneratedValue(strategy = GenerationType.AUTO)
	  public int getId() {
	    return id;
	  }


	public String getName() {
		return name;
	}


	public void setName(String name) {
		this.name = name;
	}

	public int getAgentId() {
		return agentId;
	}


	public void setAgentId(int agentId) {
		this.agentId = agentId;
	}


	public void setId(int id) {
		this.id = id;
	}


	@ManyToOne
	public MWorldObject getObjectReference() {
		return objectReference;
	}


	public void setObjectReference(MWorldObject objectReference) {
		this.objectReference = objectReference;
	}

	  
	  
}
	
	

